import request from '@/utils/request'
export const ScenicAreaSearchService = (params) =>
  request.get('/api/scenicArea/search/list/page', { params })

export const ScenicAreaAddService = (data) =>
  request.post('/api/scenicArea/add', data, {
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  })

export const ScenicAreaUpdateService = (data) =>
  request.post('/api/scenicArea/update', data, {
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  })
export const ScenicAreaDelService = (ids) => request.post('/api/scenicArea/delete', { ids })

// 添加图片
export const ScenicAreaAddImgService = (params) =>
  request.post('/api/scenicArea/update/addimage', params, {
    headers: { 'Content-Type': 'multipart/form-data' }
  })
// 更新图片
export const ScenicAreaUpdateImgService = (params) =>
  request.post('/api/scenicArea/update/image', { params })

// 审核功能
export const AuditScenicAreaService = (params) =>
  request.post('/api/scenicArea/audit', params, {
    headers: { 'Content-Type': 'application/x-www-form-urlencoded' }
  })

// 删除图片
export const delImagesService = (params) =>
  request.post('/api/scenicArea/update/deleteimage', params, {
    headers: { 'Content-Type': 'application/x-www-form-urlencoded' }
  })
